package KharkovITCourses.proc.loop.matrix_mul;

/**
 * Created with IntelliJ IDEA.
 * User: root
 * Date: 1/3/13
 * Time: 9:17 AM
 * To change this template use File | Settings | File Templates.
 */
public class MatrixUtils {
    public static int[][] mul(int[][] a, int[][] b) {

        int[][] result = new int[a.length][b[0].length];
        for (int row=0;row < a.length;row++) {
            for (int column=0;column < b[0].length;column++) {
                for (int i=0;i < a.length;i++) {
                    result[row][column] += a[row][i] * b[i][column];
                }
            }
        }
        return result;
    }
}
